package com.haina.vote.entity;
import com.haina.vote.utils.DateUtils;
import org.springframework.format.annotation.DateTimeFormat;
import java.util.Date;
import java.util.List;


public class KqFwModel {
    private Integer id;
    //编号
    private String number;
    //提交单位
    private String organization;
    //任务名称
    private String taskname;
    //联系人
    private String linkman;
    //联系电话
    private String telephone;
    //下达时间
    @DateTimeFormat(pattern = "yyyy-MM-dd")
    private Date givetime;

    private String givetimeStr;
    //完成时限
    private String timelimit;
    //任务类型01资料收集 02科技查新 03前沿动态分析整编 04“信息专员”服务 05团队学术影响力分析 06其他
    private String tasktype;
    //任务背景
    private String taskbackground;
    //任务简述
    private String taskmark;
    //具体要求
    private String specification;
    //任务完成情况
    private String taskInfo;
    //中英文关键词
    private String keywords;
    //任务反馈
    private String taskfeedback;
    //任务单状态（1、待处理 2、待修改 3、任务进行中 4、资料查找完成 5、完成）
    private Integer status;
    private String statusStr;
    private String means_url;
    //任务单创建时间
    @DateTimeFormat(pattern = "yyyy-MM-dd HH:mm")
    private Date create_time;
    private String create_timeStr;
    //任务单修改时间
    @DateTimeFormat(pattern = "yyyy-MM-dd HH:mm")
    private Date update_time;
    private String update_timeStr;
    //六位随机码
    private String code;
    private String reject;
    //任务完成情况
    private List<KqFwPerformance> kqfwPerformance;

    public Integer getId() {
        return id;
    }

    public void setId(Integer id) {
        this.id = id;
    }

    public String getNumber() {
        return number;
    }

    public void setNumber(String number) {
        this.number = number;
    }

    public String getOrganization() {
        return organization;
    }

    public void setOrganization(String organization) {
        this.organization = organization;
    }

    public String getTaskname() {
        return taskname;
    }

    public void setTaskname(String taskname) {
        this.taskname = taskname;
    }

    public String getLinkman() {
        return linkman;
    }

    public void setLinkman(String linkman) {
        this.linkman = linkman;
    }

    public String getTelephone() {
        return telephone;
    }

    public void setTelephone(String telephone) {
        this.telephone = telephone;
    }

    public Date getGivetime() {
        return givetime;
    }

    public void setGivetime(Date givetime) {
        this.givetime = givetime;
    }

    public String getTimelimit() {
        return timelimit;
    }

    public void setTimelimit(String timelimit) {
        this.timelimit = timelimit;
    }

    public String getTasktype() {
        return tasktype;
    }

    public void setTasktype(String tasktype) {
        this.tasktype = tasktype;
    }

    public String getTaskbackground() {
        return taskbackground;
    }

    public void setTaskbackground(String taskbackground) {
        this.taskbackground = taskbackground;
    }

    public String getTaskmark() {
        return taskmark;
    }

    public void setTaskmark(String taskmark) {
        this.taskmark = taskmark;
    }

    public String getSpecification() {
        return specification;
    }

    public void setSpecification(String specification) {
        this.specification = specification;
    }

    public String getKeywords() {
        return keywords;
    }

    public void setKeywords(String keywords) {
        this.keywords = keywords;
    }

    public String getTaskfeedback() {
        return taskfeedback;
    }

    public void setTaskfeedback(String taskfeedback) {
        this.taskfeedback = taskfeedback;
    }

    public Integer getStatus() {
        return status;
    }

    public void setStatus(Integer status) {
        this.status = status;
    }

    public String getStatusStr() {
        //任务单状态（1、待处理 2、待修改 3、任务进行中 4、资料查找完成 5、完成）
        if (status!=null){
            if (status==1){
                statusStr="待处理";
            }
            if (status==2){
                statusStr="待修改";
            }
            if (status==3){
                statusStr="任务进行中";
            }
            if (status==4){
                statusStr="资料查找完成";
            }if (status==5){
                statusStr="完成";
            }
        }
        return statusStr;
    }

    public void setStatusStr(String statusStr) {
        this.statusStr = statusStr;
    }

    public String getMeans_url() {
        return means_url;
    }

    public String getGivetimeStr() {
        if (givetime!=null){
            givetimeStr=DateUtils.DateToString(givetime,"yyyy-MM-dd");
        }
        return givetimeStr;
    }

    public void setGivetimeStr(String givetimeStr) {
        this.givetimeStr = givetimeStr;
    }

    public void setMeans_url(String means_url) {
        this.means_url = means_url;
    }

    public String getCode() {
        return code;
    }

    public void setCode(String code) {
        this.code = code;
    }

    public List<KqFwPerformance> getKqfwPerformance() {
        return kqfwPerformance;
    }

    public void setKqfwPerformance(List<KqFwPerformance> kqfwPerformance) {
        this.kqfwPerformance = kqfwPerformance;
    }

    public String getTaskInfo() {
        return taskInfo;
    }

    public void setTaskInfo(String taskInfo) {
        this.taskInfo = taskInfo;
    }

    public Date getCreate_time() {
        return create_time;
    }

    public void setCreate_time(Date create_time) {
        this.create_time = create_time;
    }

    public Date getUpdate_time() {
        return update_time;
    }

    public void setUpdate_time(Date update_time) {
        this.update_time = update_time;
    }

    public String getCreate_timeStr() {
        if (create_time!=null){
            create_timeStr= DateUtils.DateToString(create_time,"yyyy-MM-dd hh:mm");
        }
        return create_timeStr;
    }

    public void setCreate_timeStr(String create_timeStr) {
        this.create_timeStr = create_timeStr;
    }

    public String getUpdate_timeStr() {
        if (update_time!=null){
            update_timeStr= DateUtils.DateToString(update_time,"yyyy-MM-dd hh:mm");
        }
        return update_timeStr;
    }

    public void setUpdate_timeStr(String update_timeStr) {
        this.update_timeStr = update_timeStr;
    }

    public String getReject() {
        return reject;
    }

    public void setReject(String reject) {
        this.reject = reject;
    }

    @Override
    public String toString() {
        return "KqFwModel{" +
                "id=" + id +
                ", number='" + number + '\'' +
                ", organization='" + organization + '\'' +
                ", taskname='" + taskname + '\'' +
                ", linkman='" + linkman + '\'' +
                ", telephone='" + telephone + '\'' +
                ", givetime=" + givetime +
                ", givetimeStr='" + givetimeStr + '\'' +
                ", timelimit='" + timelimit + '\'' +
                ", tasktype='" + tasktype + '\'' +
                ", taskbackground='" + taskbackground + '\'' +
                ", taskmark='" + taskmark + '\'' +
                ", specification='" + specification + '\'' +
                ", taskInfo='" + taskInfo + '\'' +
                ", keywords='" + keywords + '\'' +
                ", taskfeedback='" + taskfeedback + '\'' +
                ", status=" + status +
                ", statusStr='" + statusStr + '\'' +
                ", means_url='" + means_url + '\'' +
                ", create_time=" + create_time +
                ", create_timeStr='" + create_timeStr + '\'' +
                ", update_time=" + update_time +
                ", update_timeStr='" + update_timeStr + '\'' +
                ", code='" + code + '\'' +
                ", kqfwPerformance=" + kqfwPerformance +
                '}';
    }
}
